<aside  class="one fourth padded border-right">
    <ul id="menu">


        <?php
        $db = new SuperDataBase();
        $query_ = "SELECT pkModule, nameModule,url from module";
        $resultListModule = $db->executeQuery($query_);
        while ($row = $db->fecth_array($resultListModule)) {
            echo '<li><a>';
            echo $row['nameModule'];
            echo "</a>";

            $_query = "SELECT pkSubModule, fkModule, nameSubModule, status,url FROM submodule s where fkModule=" . $row['pkModule'] . " and status=0";
            $resultSubModule = $db->executeQuery($_query);


            if (isset($resultSubModule)) {
                echo "<ul>";
                while ($ro2 = $db->fecth_array($resultSubModule)) {

                    echo '<li><a onclick="_onLoadPage(\'' .  $row['url'] . '\',\'' . $ro2['url'] . '\')" >';
                    echo $ro2['nameSubModule'];
                    echo '</a></li>';
                }
                echo "</ul>";
            }
            echo '</li>';
        }
        ?>



    </ul>
</aside>

